home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 11 / Cream of the Crop 11-2.iso / extra_2 / sbdemo12.zip / RELNOTES.TXT < prev    next >
Text File  |  1995-11-13  |  7KB  |  164 lines

  1.                                RELNOTES.TXT File
  2.          Release Notes file for ShowBasic Development Kit, Version 1.2
  3.                       (C) Copyright MIKSoft, Inc. 1995
  4.  
  5. This document includes updated information for the documentation provided
  6. with ShowBasic Development Kit for Windows version 1.2. 
  7. The information in this document describes the improvements and added
  8. features as compared to ShowBasic version 1.0 and 1.1.
  9.  
  10. The main emphasis in ShowBasic version 1.2 was on the compatibility 
  11. issues with Windows 95 and Windows NT operating systems. We feel that
  12. the nature of titles developed with ShowBasic requires them to be
  13. as much as possible independent of the version of Windows they are 
  14. executed on. To achieve this goal ShowBasic now automatically
  15. detects the current operating system and tries to ensure that each
  16. function will behave consistently in the current environment. 
  17.  
  18. As there are major differences between Windows 3.1, Windows 95 and
  19. Windows NT - sometimes it is required to adjust the program's behavior
  20. depending on the current environment. WinInfoSystem() function allows
  21. to detect the environment and therefore to branch execution path
  22. depending on the detected system.
  23.  
  24. The real preemptive multitasking is one of the major difference between the 
  25. 32-bit Windows NT and 95 and 16-bit Windows 3.x. It might cause troubles
  26. during keyboard/mouse simulations, when as a result of this simulations
  27. the layout of the desktop changes, i.e. new windows appear on the screen
  28. or the active window changes. Consider the following example. Let's
  29. assume that we have Notepad and Write running, and we want to type
  30. the word "notes" into Notepad and then type "writing" into Write
  31. by simulating the series of keystrokes. In Windows 3.1 we can do it
  32. the following way:
  33.  
  34. WinSetPosSizeState(WinLocate("Notepad"), NULL, SBC_WINACTIVE)
  35. Simulate("notes")
  36. WinSetPosSizeState(WinLocate("Write"), NULL, SBC_WINACTIVE)
  37. Simulate("writing")
  38.  
  39. The above sequence will work OK on Windows 3.1, however it might not work
  40. in Windows NT and Windows 95. Why? In Windows 3.1 when we activate Write 
  41. using WinSetPosSizeState() function, it is guaranteed that no other Windows 
  42. application (including ShowBasic) will receive control until Write really
  43. becomes the active window. Therefore, when ShowBasic places keystrokes into
  44. the system queue, it is guaranteed that the "writing" keystrokes will be 
  45. retrieved by Windows and played into Write. This is not true for 32-bit 
  46. operating systems because of their preemptive multitasking nature. When
  47. activation request is passed to Windows, all other applications (including
  48. ShowBasic) continue to work, and the pending keystrokes are extracted
  49. from the system queue and played into the currently active window. While
  50. Windows executes request to make Write the active window, Notepad itself
  51. may remain the active window for some time - so the beginning of "write"
  52. keystrokes can go into Notepad instead of Write. If you experiment with
  53. this, you might not observe it, it depends on the computer, operating
  54. system parameters, etc. However it can happen.
  55.  
  56. How to cure this? You can apply some delay between windows activations
  57. to ensure that the required window gets activated. For example,
  58.  
  59. WinSetPosSizeState(WinLocate("Notepad"), NULL, SBC_WINACTIVE)
  60. Simulate("notes")
  61. sleep 2
  62. WinSetPosSizeState(WinLocate("Write"), NULL, SBC_WINACTIVE)
  63. Simulate("writing")
  64.  
  65. This is not a very reliable solution. What if 2 seconds is not enough for
  66. another window to activate? It would be better to have a function that
  67. really waits until the required window gets active. We've introduced such
  68. function in version 1.2 - WinActivate(). It allows not only to pass the
  69. activation request but also to delay the following script execution until
  70. the requested window gets active and ready to receive the keystrokes.
  71. Using this function our sample can be modified to look like this:
  72.  
  73. If WinActivate("Notepad", "", 2) <> 0 Then
  74.   Simulate("notes")
  75. Endif
  76. If WinActivate("Write", "", 2) <> 0 Then
  77.   Simulate("writing")
  78. Endif
  79.  
  80. The last parameter (2) is an optional time-out for the WinActivate() to
  81. ensure that the required window is really active already. It will wait
  82. for activation no longer than 2 seconds (in our example). Check the
  83. ShowBasic Reference for further details.
  84.  
  85. What's new?
  86. ===========
  87.  
  88.  - WinActivate() function;
  89.  
  90.  - WinLocate(), WinLocateChild(), WinClickControl(), WinControlState()
  91.    functions can have an optional parameter that restricts the search 
  92.    among the windows created by a particular module;
  93.  
  94.  - DECLARE32 statement, and the ability to call functions in 32-bit DLLs;
  95.  
  96.  - New TBUSER32.DLL, and the ability to control ShowBasic from 32-bit 
  97.    programs;
  98.  
  99.  - '$INCLUDE metacommand;
  100.  
  101.  - ALIAS keyword can be used in Declare or Declare32 statements;
  102.  
  103.  - {XThenY} {YThenX} {XAndY} {Tick x} codes added to Simulate function;
  104.  
  105.  - System variable SBV_SIMWINDOW and constants SBC_SIM_NONE, SBC_SIM_VISIBLE,
  106.    SBC_SIM_ACTIVE. 
  107.    SBV_SIMWINDOW system variable allows to control window activation during
  108.    the simulations.(See Simulate() function);
  109.  
  110.  - Added PRAGMA DOUBLEDECLARATION ON|OFF and PRAGMA SEGMENT xx statements
  111.    ( see Interpret() function);
  112.  
  113.  - Constant SBC_NOCLICK (to already existing SBC_CLICK and SBC_DOUBLECLICK)
  114.    for WinClickxxx() functions;
  115.  
  116.  - 32-bit Recorder for Windows NT and Windows 95 is included, it allows to 
  117.    record events for 32-bit applications;
  118.  
  119.  - a very helpful Fatbits utility is included (freeware by John Ridges);
  120.  
  121. What's changed?
  122. ===============
  123.  
  124. There are many improvements in functionality, but most of them are
  125. "invisible". Some noticeable changes are:
  126.  
  127.  - WinClickMenuXXX functions now ensure that mouse movements occur only
  128.    vertically/horizontally. Direct mouse movement from point to point
  129.    could result in a wrong menu selection in Windows 95 (because of the
  130.    new way the menus are selected with the mouse in this system).
  131.  
  132.  - The size of the P-code has been significantly optimized; you can expect
  133.    you BEX files to become 30%-50% smaller.
  134.  
  135.  - If the first parameter of the WinLocateChild() function is NULL, it will
  136.    search not only the currently active window, but also all other windows
  137.    in order to locate the child with the given caption/ID and/or class.
  138.  
  139.  - ShowBasic Compactor, Recorder and ShowBasic IDE are improved;
  140.  
  141. Known limitations
  142. =================
  143.  
  144. For both Windows NT and Windows 95:
  145.  
  146.  - Exclusive() subroutine works only for the 16-bit environment, i.e. it 
  147.    doesn't stop the 32-bit applications running at the same time.
  148.  
  149. For Windows 95:
  150.  
  151.  - Color of the text on dialog box buttons cannot be changed;
  152.  
  153. For Windows NT:
  154.  
  155.  - flags SBC_IGNOREALLINPUT, SBC_IGNOREWATCHEDINPUT and SBC_ACCEPTWATCHEDINPUT
  156.    are not supported for the WaitInput() function;
  157.  
  158.  - WaitWinActive(), WaitWinClose(), WaitWinFocus(), WaitWinWndMsg() functions
  159.    support only events in the 16-bit applications;
  160.  
  161.  - EnableInput() is not supported;
  162.  
  163.  - PlayTune() is not supported.
  164.